<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%
	String basePath=request.getContextPath();
	String resourcePath = basePath+"/resources";
	String easyui = resourcePath+"/ymchUI";
	String jq = easyui+"/jquery-2.0.2.js";
%>
<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<link rel="stylesheet" type="text/css" href="<%=easyui %>/themes/default/easyui.css">
	<link rel="stylesheet" type="text/css" href="<%=easyui %>/themes/icon.css">
	<link rel="stylesheet" type="text/css" href="<%=resourcePath %>/css/main.css">
	<script type="text/javascript" src="<%=jq %>"></script>
	<script type="text/javascript" src="<%=easyui %>/jquery.easyui.min.js"></script>
	<script type="text/javascript" src="<%=easyui %>/easyui-lang-zh_CN.js"></script>
<title>雨幕潇潇</title>
</head>
<body>
	<form method="post">
		<fieldset>
			<legend>Basic Info</legend>
			<div>
				<label for="name">Name:<em class="required">required</em></label>
				<input type="text" name="name" id="name" />
			</div>
			<div>
				<label for="email">Email:
					<em class="feedback">Incorrect email address.Please try again</em>
				</label>
				
				<input type="text" name="email" id="email" />
			</div>
			<div>
				<label for="password">Password:</label>
				<input type="password" name="password" id="password" />
			</div>
		</fieldset>
		<fieldset>
			<legend>Details</legend>
			<div>
				<label for="introduce">Introduce:</label>
				<textarea name="introduce" id="introduce"></textarea>
			</div>
			<div>
				<label for="dateOfBirth">Date of Birth:</label>
				<input name="dateOfBirth" id="dateOfBirth" type="text" style="width:3em;">
				<label id="monthOfBirth" for="monthOfBirth" 
						style="text-indent: -1000em;width: 0;">Month of Birth:</label>
				<select name="monthOfBirth" id="monthOfBirth" 
						style="width:10em;margin-right: 0.5em">
					<option value="1">January</option>
					<option value="2">February</option>
					<option value="3">March</option>
				</select>
				<label for="yearOfBirth" 
						style="text-indent: -1000em;width: 0;">Year of Birth:</label>
				<input name="yearOfBirth" id="yearOfBirth" type="text" style="width:5em;">
			</div>
		</fieldset>
		<fieldset>
			<legend>Remember Me</legend>
			<div>
				<input type="radio" name="remember" value="1">Yes
				<input type="radio" name="remember" value="2">No
			</div>
		</fieldset>
		<div>
			
		</div>
	</form>
	<button id="ajax">
		w
	</button>
	<script type="text/javascript">
		$(function(){
			$("#ajax").bind("click",ajaxSubmit);
		});
		function ajaxSubmit(){
			$.ajax({
				url:"<%=basePath%>/account/register",
				type: 'post',
				dataType:"json",
				data:{
					"name":"asdfsdf",
					"password":"faff"
				},
				success:function(data){
					$.messager.alert("睦屋消息",data.msg,"info");
				},
				error:function(data){
					$.messager.alert("睦屋消息","链接断开了","error");
				}
			});
			
		}
	</script>
</body>
</html>